package com.xinghanlaser.applet.vo.point;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.xinghanlaser.applet.base.common.annotation.EnumValidated;
import com.xinghanlaser.applet.base.common.annotation.PhoneValidated;
import com.xinghanlaser.applet.enums.TopicTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * <p>
 *
 * <p>
 *
 * @author: mftuo 陀铭峰
 * @since: 2024/5/8 9:47
 */
@Data
@JsonIgnoreProperties(ignoreUnknown = true)
public class TopicPostVO {
    @ApiModelProperty(value = "申请单类型：0代表维保单")
    @NotNull(message = "申请单类型不能为空")
    @EnumValidated(TopicTypeEnum.class)
    private Integer topicType;

    @ApiModelProperty(value = "产品序列号")
    @NotBlank(message = "产品序列号")
    private String productSn;

    @ApiModelProperty(value = "联系人")
    @NotBlank(message = "联系人不能为空")
    private String contactUser;

    @ApiModelProperty(value = "联系人电话")
    @NotBlank(message = "联系人电话不能为空")
    @PhoneValidated(message = "手机号格式不正确")
    private String contactPhone;

    @ApiModelProperty(value = "联系地址JSON")
    @NotBlank(message = "联系地址不能为空")
    private String contactAddress;

    @ApiModelProperty(value = "问题描述")
    @NotBlank(message = "问题描述不能为空")
    private String problemDesc;

    @ApiModelProperty(value = "图片地址JSON")
    private String pictures;

    @ApiModelProperty(value = "提交者的用户名")
    @NotBlank(message = "提交者的用户名不能为空")
    private String userName;

    @ApiModelProperty(value = "提交者的用户ID")
    @NotNull(message = "提交者的用户ID不能为空")
    private Long userId;
}
